package com.ysy.api;


import com.ysy.factory.LeafFeignApiImpl;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

@FeignClient(contextId = "LeafFeignApi",value = "id-generator",fallbackFactory = LeafFeignApiImpl.class)
public interface LeafFeignApi {

    @RequestMapping(value = "/api/segment/get/{key}")
    public String getSegmentId(@PathVariable("key") String key);

    @RequestMapping(value = "/api/snowflake/get/{key}")
    public String getSnowflakeId(@PathVariable("key") String key);

}
